package serverDB;

import org.hibernate.Session;
/**
 * managing the interactions with database for the table Box
 * @author ran
 *
 */
public class BoxManager {
	private Session session = null;
	 public BoxManager(Session session) {
	  if(session == null)
	    throw new 
	      RuntimeException("Invalid session object.");
	  this.session = session;
	 }
	 public void save(Box box){
	  session.save(box);
	 }
	 public void update(Box box){
	  session.update(box);
	 }
	 public void delete(Box box) {
	  session.delete(box);
	 }

}
